package com.fyy.aop.controller;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author fyy
 * @Description
 * @Date 2021/6/29 14:06
 */
@RestController
public class IndexController {

    private static Logger logger = LoggerFactory.getLogger(IndexController.class);

    @RequestMapping(value = "/aop")
    public void testAop(Model userName){
        logger.info("请求的参数为：{}",userName.getAttribute("userName"));
    }

    @RequestMapping(value = "/aop1")
    public void testAop1(String userName){
        logger.info("请求的参数为：{}",userName);
    }

    @RequestMapping(value = "/aop2")
    public void testAop2(String userName){
        logger.info("请求的参数为：{}",userName);
    }

}
